\(\int \frac {(a+b \log (c x^n))^3}{x^3} \, dx\) [63]

   Optimal result
   Rubi [A] (verified)
   Mathematica [A] (verified)
   Maple [A] (verified)
   Fricas [B] (verification not implemented)
   Sympy [B] (verification not implemented)
   Maxima [A] (verification not implemented)
   Giac [B] (verification not implemented)
   Mupad [B] (verification not implemented)

Optimal result

Integrand size = 16, antiderivative size = 77 \[ \int \frac {\left (a+b \log \left (c x^n\right )\right )^3}{x^3} \, dx=-\frac {3 b^3 n^3}{8 x^2}-\frac {3 b^2 n^2 \left (a+b \log \left (c x^n\right )\right )}{4 x^2}-\frac {3 b n \left (a+b \log \left (c x^n\right )\right )^2}{4 x^2}-\frac {\left (a+b \log \left (c x^n\right )\right )^3}{2 x^2} \]

[Out]

-3/8*b^3*n^3/x^2-3/4*b^2*n^2*(a+b*ln(c*x^n))/x^2-3/4*b*n*(a+b*ln(c*x^n))^2/x^2-1/2*(a+b*ln(c*x^n))^3/x^2

Rubi [A] (verified)

Time = 0.04 (sec) , antiderivative size = 77, normalized size of antiderivative = 1.00, number of steps used = 3, number of rules used = 2, \(\frac {\text {number of rules}}{\text {integrand size}}\) = 0.125, Rules used = {2342, 2341} \[ \int \frac {\left (a+b \log \left (c x^n\right )\right )^3}{x^3} \, dx=-\frac {3 b^2 n^2 \left (a+b \log \left (c x^n\right )\right )}{4 x^2}-\frac {3 b n \left (a+b \log \left (c x^n\right )\right )^2}{4 x^2}-\frac {\left (a+b \log \left (c x^n\right )\right )^3}{2 x^2}-\frac {3 b^3 n^3}{8 x^2} \]

[In]

Int[(a + b*Log[c*x^n])^3/x^3,x]

[Out]

(-3*b^3*n^3)/(8*x^2) - (3*b^2*n^2*(a + b*Log[c*x^n]))/(4*x^2) - (3*b*n*(a + b*Log[c*x^n])^2)/(4*x^2) - (a + b*
Log[c*x^n])^3/(2*x^2)

Rule 2341

Int[((a_.) + Log[(c_.)*(x_)^(n_.)]*(b_.))*((d_.)*(x_))^(m_.), x_Symbol] :> Simp[(d*x)^(m + 1)*((a + b*Log[c*x^
n])/(d*(m + 1))), x] - Simp[b*n*((d*x)^(m + 1)/(d*(m + 1)^2)), x] /; FreeQ[{a, b, c, d, m, n}, x] && NeQ[m, -1
]

Rule 2342

Int[((a_.) + Log[(c_.)*(x_)^(n_.)]*(b_.))^(p_.)*((d_.)*(x_))^(m_.), x_Symbol] :> Simp[(d*x)^(m + 1)*((a + b*Lo
g[c*x^n])^p/(d*(m + 1))), x] - Dist[b*n*(p/(m + 1)), Int[(d*x)^m*(a + b*Log[c*x^n])^(p - 1), x], x] /; FreeQ[{
a, b, c, d, m, n}, x] && NeQ[m, -1] && GtQ[p, 0]

Rubi steps \begin{align*} \text {integral}& = -\frac {\left (a+b \log \left (c x^n\right )\right )^3}{2 x^2}+\frac {1}{2} (3 b n) \int \frac {\left (a+b \log \left (c x^n\right )\right )^2}{x^3} \, dx \\ & = -\frac {3 b n \left (a+b \log \left (c x^n\right )\right )^2}{4 x^2}-\frac {\left (a+b \log \left (c x^n\right )\right )^3}{2 x^2}+\frac {1}{2} \left (3 b^2 n^2\right ) \int \frac {a+b \log \left (c x^n\right )}{x^3} \, dx \\ & = -\frac {3 b^3 n^3}{8 x^2}-\frac {3 b^2 n^2 \left (a+b \log \left (c x^n\right )\right )}{4 x^2}-\frac {3 b n \left (a+b \log \left (c x^n\right )\right )^2}{4 x^2}-\frac {\left (a+b \log \left (c x^n\right )\right )^3}{2 x^2} \\ \end{align*}

Mathematica [A] (verified)

Time = 0.02 (sec) , antiderivative size = 60, normalized size of antiderivative = 0.78 \[ \int \frac {\left (a+b \log \left (c x^n\right )\right )^3}{x^3} \, dx=-\frac {4 \left (a+b \log \left (c x^n\right )\right )^3+3 b n \left (2 \left (a+b \log \left (c x^n\right )\right )^2+b n \left (2 a+b n+2 b \log \left (c x^n\right )\right )\right )}{8 x^2} \]

[In]

Integrate[(a + b*Log[c*x^n])^3/x^3,x]

[Out]

-1/8*(4*(a + b*Log[c*x^n])^3 + 3*b*n*(2*(a + b*Log[c*x^n])^2 + b*n*(2*a + b*n + 2*b*Log[c*x^n])))/x^2

Maple [A] (verified)

Time = 0.28 (sec) , antiderivative size = 116, normalized size of antiderivative = 1.51

method result size
parallelrisch \(-\frac {4 b^{3} \ln \left (c \,x^{n}\right )^{3}+6 \ln \left (c \,x^{n}\right )^{2} b^{3} n +6 \ln \left (c \,x^{n}\right ) b^{3} n^{2}+3 b^{3} n^{3}+12 a \,b^{2} \ln \left (c \,x^{n}\right )^{2}+12 \ln \left (c \,x^{n}\right ) a \,b^{2} n +6 a \,b^{2} n^{2}+12 a^{2} b \ln \left (c \,x^{n}\right )+6 a^{2} b n +4 a^{3}}{8 x^{2}}\) \(116\)
risch \(\text {Expression too large to display}\) \(2673\)

[In]

int((a+b*ln(c*x^n))^3/x^3,x,method=_RETURNVERBOSE)

[Out]

-1/8/x^2*(4*b^3*ln(c*x^n)^3+6*ln(c*x^n)^2*b^3*n+6*ln(c*x^n)*b^3*n^2+3*b^3*n^3+12*a*b^2*ln(c*x^n)^2+12*ln(c*x^n
)*a*b^2*n+6*a*b^2*n^2+12*a^2*b*ln(c*x^n)+6*a^2*b*n+4*a^3)

Fricas [B] (verification not implemented)

Leaf count of result is larger than twice the leaf count of optimal. 189 vs. \(2 (69) = 138\).

Time = 0.31 (sec) , antiderivative size = 189, normalized size of antiderivative = 2.45 \[ \int \frac {\left (a+b \log \left (c x^n\right )\right )^3}{x^3} \, dx=-\frac {4 \, b^{3} n^{3} \log \left (x\right )^{3} + 3 \, b^{3} n^{3} + 4 \, b^{3} \log \left (c\right )^{3} + 6 \, a b^{2} n^{2} + 6 \, a^{2} b n + 4 \, a^{3} + 6 \, {\left (b^{3} n + 2 \, a b^{2}\right )} \log \left (c\right )^{2} + 6 \, {\left (b^{3} n^{3} + 2 \, b^{3} n^{2} \log \left (c\right ) + 2 \, a b^{2} n^{2}\right )} \log \left (x\right )^{2} + 6 \, {\left (b^{3} n^{2} + 2 \, a b^{2} n + 2 \, a^{2} b\right )} \log \left (c\right ) + 6 \, {\left (b^{3} n^{3} + 2 \, b^{3} n \log \left (c\right )^{2} + 2 \, a b^{2} n^{2} + 2 \, a^{2} b n + 2 \, {\left (b^{3} n^{2} + 2 \, a b^{2} n\right )} \log \left (c\right )\right )} \log \left (x\right )}{8 \, x^{2}} \]

[In]

integrate((a+b*log(c*x^n))^3/x^3,x, algorithm="fricas")

[Out]

-1/8*(4*b^3*n^3*log(x)^3 + 3*b^3*n^3 + 4*b^3*log(c)^3 + 6*a*b^2*n^2 + 6*a^2*b*n + 4*a^3 + 6*(b^3*n + 2*a*b^2)*
log(c)^2 + 6*(b^3*n^3 + 2*b^3*n^2*log(c) + 2*a*b^2*n^2)*log(x)^2 + 6*(b^3*n^2 + 2*a*b^2*n + 2*a^2*b)*log(c) +
6*(b^3*n^3 + 2*b^3*n*log(c)^2 + 2*a*b^2*n^2 + 2*a^2*b*n + 2*(b^3*n^2 + 2*a*b^2*n)*log(c))*log(x))/x^2

Sympy [B] (verification not implemented)

Leaf count of result is larger than twice the leaf count of optimal. 168 vs. \(2 (76) = 152\).

Time = 0.25 (sec) , antiderivative size = 168, normalized size of antiderivative = 2.18 \[ \int \frac {\left (a+b \log \left (c x^n\right )\right )^3}{x^3} \, dx=- \frac {a^{3}}{2 x^{2}} - \frac {3 a^{2} b n}{4 x^{2}} - \frac {3 a^{2} b \log {\left (c x^{n} \right )}}{2 x^{2}} - \frac {3 a b^{2} n^{2}}{4 x^{2}} - \frac {3 a b^{2} n \log {\left (c x^{n} \right )}}{2 x^{2}} - \frac {3 a b^{2} \log {\left (c x^{n} \right )}^{2}}{2 x^{2}} - \frac {3 b^{3} n^{3}}{8 x^{2}} - \frac {3 b^{3} n^{2} \log {\left (c x^{n} \right )}}{4 x^{2}} - \frac {3 b^{3} n \log {\left (c x^{n} \right )}^{2}}{4 x^{2}} - \frac {b^{3} \log {\left (c x^{n} \right )}^{3}}{2 x^{2}} \]

[In]

integrate((a+b*ln(c*x**n))**3/x**3,x)

[Out]

-a**3/(2*x**2) - 3*a**2*b*n/(4*x**2) - 3*a**2*b*log(c*x**n)/(2*x**2) - 3*a*b**2*n**2/(4*x**2) - 3*a*b**2*n*log
(c*x**n)/(2*x**2) - 3*a*b**2*log(c*x**n)**2/(2*x**2) - 3*b**3*n**3/(8*x**2) - 3*b**3*n**2*log(c*x**n)/(4*x**2)
 - 3*b**3*n*log(c*x**n)**2/(4*x**2) - b**3*log(c*x**n)**3/(2*x**2)

Maxima [A] (verification not implemented)

none

Time = 0.19 (sec) , antiderivative size = 135, normalized size of antiderivative = 1.75 \[ \int \frac {\left (a+b \log \left (c x^n\right )\right )^3}{x^3} \, dx=-\frac {3}{8} \, {\left (n {\left (\frac {n^{2}}{x^{2}} + \frac {2 \, n \log \left (c x^{n}\right )}{x^{2}}\right )} + \frac {2 \, n \log \left (c x^{n}\right )^{2}}{x^{2}}\right )} b^{3} - \frac {3}{4} \, a b^{2} {\left (\frac {n^{2}}{x^{2}} + \frac {2 \, n \log \left (c x^{n}\right )}{x^{2}}\right )} - \frac {b^{3} \log \left (c x^{n}\right )^{3}}{2 \, x^{2}} - \frac {3 \, a b^{2} \log \left (c x^{n}\right )^{2}}{2 \, x^{2}} - \frac {3 \, a^{2} b n}{4 \, x^{2}} - \frac {3 \, a^{2} b \log \left (c x^{n}\right )}{2 \, x^{2}} - \frac {a^{3}}{2 \, x^{2}} \]

[In]

integrate((a+b*log(c*x^n))^3/x^3,x, algorithm="maxima")

[Out]

-3/8*(n*(n^2/x^2 + 2*n*log(c*x^n)/x^2) + 2*n*log(c*x^n)^2/x^2)*b^3 - 3/4*a*b^2*(n^2/x^2 + 2*n*log(c*x^n)/x^2)
- 1/2*b^3*log(c*x^n)^3/x^2 - 3/2*a*b^2*log(c*x^n)^2/x^2 - 3/4*a^2*b*n/x^2 - 3/2*a^2*b*log(c*x^n)/x^2 - 1/2*a^3
/x^2

Giac [B] (verification not implemented)

Leaf count of result is larger than twice the leaf count of optimal. 203 vs. \(2 (69) = 138\).

Time = 0.35 (sec) , antiderivative size = 203, normalized size of antiderivative = 2.64 \[ \int \frac {\left (a+b \log \left (c x^n\right )\right )^3}{x^3} \, dx=-\frac {b^{3} n^{3} \log \left (x\right )^{3}}{2 \, x^{2}} - \frac {3 \, {\left (b^{3} n^{3} + 2 \, b^{3} n^{2} \log \left (c\right ) + 2 \, a b^{2} n^{2}\right )} \log \left (x\right )^{2}}{4 \, x^{2}} - \frac {3 \, {\left (b^{3} n^{3} + 2 \, b^{3} n^{2} \log \left (c\right ) + 2 \, b^{3} n \log \left (c\right )^{2} + 2 \, a b^{2} n^{2} + 4 \, a b^{2} n \log \left (c\right ) + 2 \, a^{2} b n\right )} \log \left (x\right )}{4 \, x^{2}} - \frac {3 \, b^{3} n^{3} + 6 \, b^{3} n^{2} \log \left (c\right ) + 6 \, b^{3} n \log \left (c\right )^{2} + 4 \, b^{3} \log \left (c\right )^{3} + 6 \, a b^{2} n^{2} + 12 \, a b^{2} n \log \left (c\right ) + 12 \, a b^{2} \log \left (c\right )^{2} + 6 \, a^{2} b n + 12 \, a^{2} b \log \left (c\right ) + 4 \, a^{3}}{8 \, x^{2}} \]

[In]

integrate((a+b*log(c*x^n))^3/x^3,x, algorithm="giac")

[Out]

-1/2*b^3*n^3*log(x)^3/x^2 - 3/4*(b^3*n^3 + 2*b^3*n^2*log(c) + 2*a*b^2*n^2)*log(x)^2/x^2 - 3/4*(b^3*n^3 + 2*b^3
*n^2*log(c) + 2*b^3*n*log(c)^2 + 2*a*b^2*n^2 + 4*a*b^2*n*log(c) + 2*a^2*b*n)*log(x)/x^2 - 1/8*(3*b^3*n^3 + 6*b
^3*n^2*log(c) + 6*b^3*n*log(c)^2 + 4*b^3*log(c)^3 + 6*a*b^2*n^2 + 12*a*b^2*n*log(c) + 12*a*b^2*log(c)^2 + 6*a^
2*b*n + 12*a^2*b*log(c) + 4*a^3)/x^2

Mupad [B] (verification not implemented)

Time = 0.41 (sec) , antiderivative size = 111, normalized size of antiderivative = 1.44 \[ \int \frac {\left (a+b \log \left (c x^n\right )\right )^3}{x^3} \, dx=-\frac {\frac {a^3}{2}+\frac {3\,a^2\,b\,n}{4}+\frac {3\,a\,b^2\,n^2}{4}+\frac {3\,b^3\,n^3}{8}}{x^2}-\frac {\ln \left (c\,x^n\right )\,\left (3\,a^2\,b+3\,a\,b^2\,n+\frac {3\,b^3\,n^2}{2}\right )}{2\,x^2}-\frac {{\ln \left (c\,x^n\right )}^2\,\left (\frac {3\,n\,b^3}{2}+3\,a\,b^2\right )}{2\,x^2}-\frac {b^3\,{\ln \left (c\,x^n\right )}^3}{2\,x^2} \]

[In]

int((a + b*log(c*x^n))^3/x^3,x)

[Out]

- (a^3/2 + (3*b^3*n^3)/8 + (3*a*b^2*n^2)/4 + (3*a^2*b*n)/4)/x^2 - (log(c*x^n)*(3*a^2*b + (3*b^3*n^2)/2 + 3*a*b
^2*n))/(2*x^2) - (log(c*x^n)^2*(3*a*b^2 + (3*b^3*n)/2))/(2*x^2) - (b^3*log(c*x^n)^3)/(2*x^2)